# Contributor: Siva Mahadevan <me@svmhdvn.name>
# Maintainer: Siva Mahadevan <me@svmhdvn.name>
pkgname=kak-lsp
pkgver=15.0.1
pkgrel=0
pkgdesc="Language Server Protocol client for Kakoune implemented in Rust"
url="https://github.com/kak-lsp/kak-lsp"
arch="all !s390x !riscv64" # limited by cargo
license="Unlicense OR MIT"
makedepends="cargo cargo-auditable"
source="$pkgname-$pkgver.tar.gz::https://github.com/kak-lsp/kak-lsp/archive/v$pkgver.tar.gz"


prepare() {
	default_prepare

	cargo fetch --target="$CTARGET" --locked
}

build() {
	cargo auditable build --frozen --release
}

check() {
	cargo test --frozen
}

package() {
	install -Dm755 "target/release/$pkgname" "$pkgdir/usr/bin/$pkgname"
}

sha512sums="
46e3d054e30be698a58b23fa5818cc29ebee6ddacdd7189af23a2faa20151bde779bd556034d668f50127ee0cd023b5ad6582c4fedfd22b6d7e40fa0dd928b13  kak-lsp-15.0.1.tar.gz
"
